package com.streamax.s17.mqs.business.service;

import com.streamax.s17.mqs.api.model.dto.MsgRetrieveDTO;
import com.streamax.s17.mqs.api.model.request.MsgRetrieveRQ;
import com.streamax.s17.mqs.business.dao.entity.DeviceMessage;

import java.util.List;

/**
 * @Description
 * @ClassName IMsgQueryService
 * @Author liwei
 * @Date 2019/8/13 17:34
 * @Version 2.0.2
 */
public interface IMsgQueryService {


    /** 持久化
     * @param msgs 消息对象列表
     * @param measurement
     * @return
     * @Description: 消息对象持久化
     */
    void persistenceMsg(List<DeviceMessage> msgs, String measurement);


    /** 查询
     * @param request 检索请求对象
     * @return List<DeviceMessage> 消息集合
     * @Description: 消息对象持久化
     */
    List<MsgRetrieveDTO> search(MsgRetrieveRQ request);
}
